<template>
  <van-notice-bar
    :left-icon="require('@/assets/images/index/logo_say.png')"
    :scrollable="false"
    :background="'#fff'"
    :color="'000'"
  >
    <van-swipe
      vertical
      class="notice-swipe"
      :autoplay="3000"
      :show-indicators="false"
    >
      <van-swipe-item v-for="(item, index) in noticeText" :key="index">{{item}}</van-swipe-item>
    </van-swipe>
  </van-notice-bar>
</template>

<script>
import { NoticeBar } from "vant";
import { Swipe, SwipeItem } from "vant";

export default {
  components: {
    [NoticeBar.name]: NoticeBar,
    [Swipe.name]: Swipe,
    [SwipeItem.name]: SwipeItem,
  },
  data() {
    return {
      noticeText: [
        '我们来啦！易凯商城App让您购物无忧',
        '附近商家一点通，让您购物不出门更省心',
        '年末检验智商的时候来啦，这些传言信过多少',
        '易凯商城App-携手快递、停车等社区服务！',
        '那么多购物类App，易凯感谢您的选择和信任！',
        'iPad的完美替代品，小米平板2评测',
        '买手机不求人，教你一分钟看懂手机参数',
        '民族旗舰 华为Mate8主观体验报告',
        '虽然这手机有点短命，但不妨碍它大卖'
      ]
    }
  }
};
</script>

<style lang="less" scoped>
::v-deep .van-icon__image {
  width: 65px;
  height: 40px;
  margin-right: 10px;
  margin-top: 4px;
}
.notice-swipe {
  height: 40px;
  line-height: 40px;
}
</style>
